package com.gopay.common.user.manager.impl;

import com.gopay.common.domain.cust.CustInfoWhitelist;
import com.gopay.common.user.dao.CustInfoWhitelistDAO;
import com.gopay.common.user.manager.CustInfoWhitelistManager;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.io.Serializable;
import java.util.List;
import java.util.Map;

/**
 * 网联项目白名单
 * @author dong-wang5@hnair.com
 * @date 2018-04-09 16:54:02
 */
@Service("custInfoWhitelistManager")
public class CustInfoWhitelistManagerImpl implements CustInfoWhitelistManager {

    @Resource(name = "custInfoWhitelistDAO")
    private CustInfoWhitelistDAO custInfoWhiteListDAO;

    @Override
    public CustInfoWhitelist get(Serializable id) {
        return custInfoWhiteListDAO.find(CustInfoWhitelist.class, id);
    }

    @Override
    public List<CustInfoWhitelist> get(Map<Object, Object> paraMap) {
        return null;
    }

    @Override
    public List<CustInfoWhitelist> getAll() {
        return custInfoWhiteListDAO.findAll(CustInfoWhitelist.class);
    }

    @Override
    public CustInfoWhitelist findByCustId(String custId, String type) {
        return custInfoWhiteListDAO.findByCustId(custId,type);
    }

    @Override
    public List<CustInfoWhitelist> findByCorpName(String corpName, String type) {
        return custInfoWhiteListDAO.findByCorpName(corpName,type);
    }
}
